package com.hwj.service;

import com.github.pagehelper.PageInfo;
import com.hwj.entity.Post;
import javafx.geometry.Pos;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Set;

public interface PostService {
    PageInfo<Post> page(Post post,String postTypeName,Integer PageNum,Integer PageSize);

    PageInfo<Post> pageManage(Post post,Integer PageNum,Integer PageSize);

    int insertSelective(Post record);

    int updateByPrimaryKey(Post record);

    int deleteByPrimaryKey(Long id);
    int insert(Post record);
    List<Post> selectView();
    List<Post> selectFavorites();

    List<Post> selectLikes();

    Post selectByPrimaryKey(Long id);

    List<Post> selectByUserIdPosts(Long userId);

    Set selectRecommend(Long postId);


    PageInfo<Post> pageExam(Post post, Integer pageNum, Integer pageSize);

    List<Post> myStarPost(Long userId);

    List<Post> myExamPost(Long userId);

    List<Post> myPublishPost (Long userId);

    PageInfo<Post> search(String title,Integer pageNum,Integer pageSize,Long userId);

    PageInfo<Post> tag(String tag,Integer pageNum,Integer pageSize);

    List<Post> listAll();

    int deleteForever(Long postId);

    List<Post> underPost(Long userId);

    List<Post> myLikePost(Long userId);

    List<Post> myPost(long l);
}
